LangChain is an open-source framework for building applications powered by large language models (LLMs). It provides abstractions for chains, agents, memory, and retrieval to help developers compose LLM workflows quickly.

LangChain supports multiple LLM providers including OpenAI, Anthropic, Google Gemini, Mistral, and local models via Ollama. Its unified interface lets you swap providers without rewriting application logic.

The core primitives in LangChain are Runnables (composable units), Chains (sequences of Runnables via LCEL), Agents (LLMs that decide which tools to call), Memory (conversation history), and Retrievers (interfaces for fetching relevant documents).

LangChain Expression Language (LCEL) uses the pipe operator (|) to compose chains declaratively. It supports streaming, async execution, parallel branching, and fallbacks out of the box.

LangChain integrates with over 50 vector stores, 100+ document loaders, and dozens of embedding providers. This makes it the most widely adopted framework for production LLM applications.
